package com.syaccp.service;

import com.github.pagehelper.PageInfo;
import com.syaccp.model.TCustomerBill;
import com.syaccp.model.TWithdrawalDetails;
import com.baomidou.mybatisplus.extension.service.IService;
import io.lettuce.core.dynamic.annotation.Param;
import org.springframework.transaction.annotation.Transactional;

import java.sql.SQLException;
import java.util.List;

/**
 *
 */
public interface TWithdrawalDetailsService extends IService<TWithdrawalDetails> {
    //查询全部体现详情  加上 用户表中的用户余额，以及用户消费总金额
    List<TWithdrawalDetails> listAll(TWithdrawalDetails tWithdrawalDetails) throws SQLException;




    //分页查询
    PageInfo<TWithdrawalDetails> PagingQueryWithdrawal(Integer index, TWithdrawalDetails tWithdrawalDetails) throws SQLException;


    //转账  操作两个表  资金流水表:修改status状态  员工表  修改员工剩余余额,和消费总金额   公司表:修改公司余额
    //转账  操作两个表  资金流水表:修改status状态  员工表  修改员工剩余余额,和消费总金额   公司表:修改公司余额
    int updateStatus(TWithdrawalDetails tWithdrawalDetails) throws SQLException;
    int updateCustomer(TWithdrawalDetails tWithdrawalDetails) throws SQLException;
    int updateDept(TWithdrawalDetails tWithdrawalDetails) throws SQLException;

    TWithdrawalDetails WithdrawalOfCompanyBalance(TWithdrawalDetails tWithdrawalDetails) throws SQLException;
    int updateCustomer1(TWithdrawalDetails tWithdrawalDetails) throws SQLException;
    int updateDept1(TWithdrawalDetails tWithdrawalDetails) throws SQLException;











    TWithdrawalDetails information();

    List<TWithdrawalDetails>queryCondition(Integer status);

    int alterTheState(TWithdrawalDetails details);

    //新增备注的方法
    int insertRemark(TWithdrawalDetails withdrawalDetails) throws SQLException;

    //修改状态的方法
    int updateState (TWithdrawalDetails withdrawalDetails) throws SQLException;





}
